package com.wiloon.java8x.thread.exchanger;

/**
 * Created by wiloon on 6/2/17;
 */

import java.util.concurrent.Exchanger;

public class ExchangerTest {

    public static void main(String[] args) {
        Exchanger<Integer> exchanger = new Exchanger<Integer>();
        new Thread(new ThreadA(exchanger)).start();
        new Thread(new ThreadB(exchanger)).start();
    }

}